<template>
  <div class="home-header">
    <div class="home-header-logo">
      <img src="@/assets/img/logo.png" alt="">
    </div>
    <div class="header-search" @click="goSearch">
      <i class="iconfont icon-fangdajing"></i>
      搜索商品名称
    </div>
    <div class="header-my">
      <i class="iconfont icon-wode-copy"></i>
    </div>
  </div>
</template>

<script>
export default {
  name: 'Header',
  methods: {
    goSearch () {
      this.$router.push('/search')
    }
  }
}
</script>

<style lang="scss" scoped>
.home-header {
  display: flex;
  justify-content: space-between;
  line-height: 1.333333rem;
  background-color: #eee;
  padding-bottom: .16rem;
  .home-header-logo {
    width: .666667rem;
    height: .666667rem;
    margin-left: .533333rem;
    img {
      width: .666667rem;
    }
  }
  .header-search {
    width: 65%;
    height: .666667rem;
    line-height: .666667rem;
    padding: .08rem 0;
    margin-top: .106667rem;
    border: 1px solid #ccc;
    font-size: .426667rem;
    color: #999;
    background-color: #fff;
    .icon-fangdajing {
      padding-left: .133333rem;
      font-size: .426667rem;
    }
  }
  .header-my{
    width: .666667rem;
    height: .666667rem;
    margin-right: .533333rem;
    .icon-wode-copy {
      color: #999;
      font-size: .533333rem;
    }
  }
}
</style>
